#include "Subject.h"

Subject::Subject(){
    id = "";
    sname = "";
    stype = "";
    credit = 0;
    presub = "";
    percent_midterm = 0;
}

Subject::Subject(string i_id,string i_sname,string i_stype,short i_credit,string i_presub,short i_percent_midterm){
    id = i_id;
    sname = i_sname;
    stype = i_stype;
    credit = i_credit;
    presub = i_presub;
    percent_midterm = i_percent_midterm;
}

void Subject::Show(){
    cout<<id<<":"<<sname<<":"<<stype<<":"<<credit<<":"<<presub<<":"<<percent_midterm<<"\n";
}

void Subject::Set_sname(string n_sname){
    sname = n_sname;
}

void Subject::Set_stype(string n_stype){
    stype = n_stype;
}
void Subject::Set_credit(short n_credit){
    credit = n_credit;
}

void Subject::Set_presub(string n_presub){
    presub = n_presub;
}

void Subject::Set_percent_midterm(short n_percent_midterm){
    percent_midterm = n_percent_midterm;
}

string Subject::Get_id(){
    return id;
}

string Subject::Get_sname(){
    return sname;
}

string Subject::Get_stype(){
    return stype;
}

short Subject::Get_credit(){
    return credit;
}

string Subject::Get_presub(){
    return presub;
}

short Subject::Get_percent_midterm(){
    return percent_midterm;
}
